package sort;

public class SelectSort {

    public static void main(String arg[]) {

        int arr[] = new int[]{123, 12, 31, 23, 4523, 2, 345, 234, 234, 2};

        for (int i = 0; i < arr.length; i++) {
            for (int j = i + 1; j < arr.length; j++) {
                if (arr[j] < arr[i]) {
                    int _temp = arr[i];
                    arr[i] = arr[j];
                    arr[j] = _temp;
                }
            }
        }

        for (int i = 0; i < arr.length; i++)
            System.out.println(arr[i]);

    }
}
